﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using com.nm.Attributes;
using Newtonsoft.Json;

namespace BaseAPI.model
{
   public class UserData
    {
        /// <summary>
        /// 用户列表
        /// </summary>
        public class ListData :ModifyData
        {
            [ParamDescription("所属部门")]
            public string DeptName { get; set; }

            [ParamDescription("岗位")]
            public string PostName { get; set; }

            [ParamDescription("角色")]
            public string RoleName { get; set; }

            [ParamDescription("头像地址")]
            public string ImageUrl { get; set; }
        }

        public class ModifyData:CreateData
        {
            [ParamDescription("用户ID")]
            public int UserID { get; set; }
        }

        #region 创建用户信息
        public class CreateData
        {
            [ParamDescription("用户编号")]
            public string UserNo { get; set; }

            [ParamDescription("用户名称")]
            public string UserName { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("登陆密码")]
            public string PassWord { get; set; }

            [ParamDescription("登陆账号")]
            public string LoginAccount { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("邮箱地址")]
            public string Email { get; set; }

            [ParamDescription("用户类型:1-系统账号,2-普通账号")]
            public int UserType { get; set; }

            [ParamDescription("用户状态1-在职,2-离职")]
            public int UserStatus { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("性别")]
            public bool Sex { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("入职时间")]
            public DateTime EntryDate { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("省")]
            public string Province { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("市")]
            public string City { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("区")]
            public string Area { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("详细地址")]
            public string Address { get; set; }

            [ParamDescription("手机号码")]
            public string Tel { get; set; }

            [ParamDescription("所属部门")]
            public int DeptID { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("部门级数")]
            public int DeptGrade { get; set; }

            [ParamDescription("岗位")]
            public int PostID { get; set; }

            [ParamDescription("是否有效")]
            public bool IsEffective { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("删除标识")]
            public bool IsRemove { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("创建者")]
            public string Creator { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("创建时间")]
            public DateTime CreateDate { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("备注")]
            public string Memo { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("所属店铺")]
            public string ShopID { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("头像")]
            public Guid Avatar { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("系统类型")]
            public string SysType { get; set; }

            [ParamDescription("头像地址")]
            public string ImageUrl { get; set; }
        }
        #endregion
    }
}
